import Vue from 'vue'
import Router from 'vue-router'
import MyVuex from '@/views/MyVuex'

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      component: MyVuex
    },
    {
      path: '/mySlot',
      component: () => import('@/views/MySlot/MySlot')
    },
    {
      path: '/form',
      component: () => import('@/views/Form')
    },
    {
      path: '/cascader',
      component: () => import('@/views/Cascader')
    },
    {
      path: '/cascader2',
      component: () => import('@/views/Cascader2')
    },
    {
      path: '/cascader3',
      component: () => import('@/views/Cascader3')
    },
    {
      path: '/cascader4',
      component: () => import('@/views/Cascader4')
    },
    {
      path: '/myTable',
      component: () => import('@/views/MyTable')
    },
    {
      path: '/myTable2',
      component: () => import('@/views/MyTable2')
    },
    {
      path: '/rich-text',
      component: () => import('@/views/MyRichText/')
    },
    {
      path: '/draggable',
      component: () => import('@/views/MyDraggable')
    },
    {
      path: '/upload',
      component: () => import('@/views/UpLoad')
    },
    {
      path: '/keepalive',
      component: () => import('@/views/KeepAlive')
    },
    {
      path: '/keepalivechild',
      component: () => import('@/views/KeepAliveChild')
    },
    {
      path: '/myStep',
      name: 'MyStep', // 如果跳转时使用 name, 需要指定这个属性
      component: () => import('@/views/MyStep')
    },
    {
      path: '/myDialog',
      component: () => import('@/views/MyDialog')
    },
    {
      path: '/myDrawer',
      component: () => import('@/views/MyDrawer')
    },
    {
      path: '/myAxios',
      component: () => import('@/views/Myaxios')
    },
    {
      path: '/myCompVisible',
      component: () => import('@/views/MyCompVisible/MyCompVisible')
    },
    {
      path: '/myLoading',
      component: () => import('@/views/MyLoading')
    },
    {
      path: '/myUeditor',
      component: () => import('@/views/MyUeditor')
    },
    {
      path: '/myUeditor2',
      component: () => import('@/views/MyUeditor2')
    },
    {
      path: '/myInfinite',
      component: () => import('@/views/MyInfinite')
    },
    {
      path: '/myTree',
      component: () => import('@/views/MyTree')
    },
    {
      path: '/myTag',
      component: () => import('@/views/Mytag')
    },
    {
      path: '/myRouter',
      component: () => import('@/views/MyRouter')
    },
    {
      path: '/myProvide',
      component: () => import('@/views/MyInject/MyProvide')
    },
    {
      path: '/myBus',
      component: () => import('@/views/MyBus/MyBus')
    }
  ]
})
